package com.xdf.ecommerce.dao;

import com.mybatisflex.core.BaseMapper;
import com.xdf.ecommerce.entity.EcommerceGoods;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

/**
 * @author chanchaw
 * @create 2025-10-27 21:47
 */
@Repository
public interface EcommerceGoodsMapper extends BaseMapper<EcommerceGoods> {
    @Select("select * from t_ecommerce_goods where goods_category=#{goodsCategory} and brand_category = #{brandCategory} and goods_name = #{goodsName} order by id desc limit 1")
    EcommerceGoods findByGoodsNameAndMultCategory(@Param("goodsCategory") String goodsCategory, @Param("brandCategory") String brandCategory, @Param("goodsName") String goodsName);
}
